require("TSLib")
require("BaseClass")
require("PointLib")

-- 葫芦娃的应用包名
local appName  = "com.xxxx.hlwzf.sj49you"

-- 屏幕大小
local width,height = getScreenSize()

-- 
local options = {
	["dim"] = 90,
	["flag"] = true
}


local begin_fight = {
	{ 1425,  750, 0xe3b623},
	{ 1392,  752, 0xfffcdf},
	{ 1459,  751, 0xfffce0},
	{ 1426,  783, 0xfffbc5},
	{ 1386,  799, 0x8a6717},
	{ 1460,  804, 0x7c5d15},
	{ 1423,  825, 0x7d5e16},
	{ 1383,  782, 0xb9901e},
	{ 1467,  782, 0xb8901e},
}

local end_fight = {
	{ 1466,  744, 0xd1a21d},
	{ 1455,  767, 0xfffbc4},
	{ 1419,  787, 0xfffaa9},
	{ 1419,  766, 0xfffbc5},
	{ 1402,  764, 0xb98f1d},
	{ 1442,  739, 0xdcb124},
	{ 1448,  790, 0x95701a},
	{ 1430,  800, 0x886618},
	{ 1391,  778, 0xa37b1b},
	{ 1467,  744, 0xd1a21e},
}

local go_on_fight = {
	{  184,  737, 0xdeb324},
	{  160,  853, 0xffffff},
	{  190,  858, 0xfefefe},
	{  234,  862, 0xfbfbfb},
	{  160,  806, 0x816117},
	{  191,  769, 0xfffbc1},
	{  190,  739, 0xdbaf22},
	{  143,  766, 0xb58d1d},
	{  168,  767, 0xfffbc4},
	{  184,  737, 0xdeb324},
}


-- 本地雷电模拟器 ip  127.0.0.1

--

--初始化屏幕
function _InitScreenSize()
	toast("已经得到当前屏幕尺寸宽度："..width.."高度："..height,1)
	if width == 1600 and height == 900 then
		toast("屏幕初始化成功",1);
		_点阵初始化()
		toast("点阵初始化完成",1)
		_DebugSwitch = true
	else
		dialog("请把模拟器屏幕设置为1600 x 900", 0)
		lua_exit();
	end
end


function _initGame()
	init(AppName,0);
	_InitScreenSize()
end



--游戏主流程
function _GameFlow()
	while (true) do
	  _表找色点击(组队战斗点阵,组队战斗点击,75)
	end
end


_initGame()
_GameFlow()

